#region Copyright
/// <copyright>
/// Copyright (c) 2007 Ilia Shramko.
/// Released under the terms of the GNU General Public License.
/// </copyright>
#endregion

using System;
using System.Collections.Generic;
using System.Text;
using System.Runtime.InteropServices;

namespace Osh.Media
{
	public interface ITimeline
	{
		ITimelineInfo CaptureState();

		bool CanSeek { get; }
		/// <summary>
		/// Sets playback position within the timeline.
		/// </summary>
		/// <param name="position">A new time within the timeline.</param>
		/// <returns>The new time within the timeline.</returns>
		DateTime? SeekTo(DateTime position);
		/// <summary>
		/// Sets playback position within the timeline.
		/// </summary>
		/// <param name="offset">Offset in milliseconds.</param>
		/// <returns>The new time within the timeline.</returns>
		DateTime? SeekBy(int offset);
		[ComVisible(false)]
		DateTime? SeekBy(TimeSpan offset);

		event EventHandler<TimelineChangeArgs> Change;
	}
}
